package com.baitengsoft.patentservicemonitor.job.service.impl;


import com.baitengsoft.patentservicemonitor.job.dao.PatentHubDataDao;
import com.baitengsoft.patentservicemonitor.job.entity.PatentHubDataEntity;
import com.baitengsoft.patentservicemonitor.job.service.PatentHubDataService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @author wangze
 * @date 2018-09-29 17:40.
 **/
@Service
public class PatentHubDataImpl implements PatentHubDataService {

    @Autowired
    private PatentHubDataDao dao;


    @Override
    public void save(PatentHubDataEntity entity) {
        dao.save(entity);
    }

    @Override
    public List<PatentHubDataEntity> pagination(int pageIndex, int pageSize) {
        return dao.pagination((pageIndex - 1) * pageSize, pageSize);
    }

    @Override
    public void updateJson(PatentHubDataEntity entity) {
        dao.updateJson(entity);
    }
}
